package com.mercury.controller;

import com.mercury.exception.MercuryException;
import org.springframework.web.bind.annotation.ControllerAdvice;
import org.springframework.web.bind.annotation.ExceptionHandler;

/**
 * @author ：tx
 * @description： 对所有控制器的异常处理
 * @date ：Created in 2019/3/7 16:50
 * @modified By：
 * @version:
 */
@ControllerAdvice
public class ExceprionHandlerAdvice {

    @ExceptionHandler(MercuryException.class)
    public String errorHappend(){
        return "indexView";
    }

}
